/*
 * POJ2965: The Pilots Brothers' refrigerator
 */

/*-------- Includes --------*/
#include <stdio.h>
#include <stdlib.h>

using namespace std;

/*-------- Main Function --------*/
int main(int argc, char const *argv[])
{
    int flip[16] = { 0 };

    // get input
    int i = 0;
    int x, y;
    int ch;
    while ((ch = getchar()) != EOF) {
        if        (ch == '+') {
            x = i / 4;
            y = i % 4;

            for (int k = 0; k < 4; k++) {
                flip[x * 4 + k]++;
                flip[k * 4 + y]++;
            }
            flip[i]--;

            i++;
        } else if (ch == '-') {
            i++;
        }
    }

    // trim useless operations and print
    int        count = 0;
    for (i = 0; i < 16; i++) {
        if (flip[i] % 2 == 1) {
            flip[i] = 1;
            count++;
        } else {
            flip[i] = 0;
        }
    }

    printf("%d\n", count);

    for (i = 0; i < 16; i++) {
        if (flip[i] == 1) {
            x = i / 4 + 1;
            y = i % 4 + 1;

            printf("%d %d\n", x, y);
        }
    }
}
